package com.songshuai.webapi.permission.controller;

import com.songshuai.webapi.baseapi.pojo.QueryResponse;
import com.songshuai.webapi.permission.dto.response.ClientListResDto;
import com.songshuai.webapi.permission.service.ClientService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Slf4j
@Api("app")
@RestController
@RequestMapping("/api/client/")
public class ClientController {

    @Autowired
    private ClientService clientService;

    @ApiOperation(value = "获取app列表")
    @GetMapping("queryAppList")
    public QueryResponse<List<ClientListResDto>> queryAppList(){
        return QueryResponse.setResData(clientService.queryAppList());
    }
}
